/**
 * Created by asus on 2017/8/29.
 */
/**
 * 根据指定行数列数动态构建表格
 * @param rownum 行数
 * @param colnum 列数
 * @param tableId 生成表的ID
 */
const crossTable = {
  createCrossTable: function (rownum,colnum,tableId) {
    var crossTable = $("#"+tableId);
    for(var i = 0 ; i < rownum ; i ++){
      var trStr = "<tr>"
      var tdStr = "";
      for(var j = 0; j < colnum ; j ++){
        tdStr += "<td style='width: 100px;'></td>";
      }
      trStr += tdStr;
      trStr += "</tr>";
      $(trStr).appendTo(crossTable);
    }
    // var trStr = "<tr rowspan='"+ rowmun + "'>"
    // trStr+="<td style='width: 100px;' colspan='"+ colnum + "'></td>"
    // trStr += "</tr>";
    // crossTable.html(trStr)
  }
}
export default crossTable
